<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
  <script src="../vue.js"></script>
</head>

<body>

  <div id="app">

    <hr>

    <ul>
      <li v-for="(item,index) in cities" :key="index">{{item.name}}--{{index}}</li>
    </ul>
    <hr>
    <ul>
      <li v-for="(value,key,index) in user">{{key}}--{{value}}-{{index}}</li>
    </ul>


  </div>

  <script>
    var cities = [{ name: 'beijing', id: 1 }, { name: 'tianjing', id: 2 }, { name: 'shanghai', id: 3 }]
    var vm = new Vue({
      el: "#app",
      data: {
        cities,
        type: 'a',
        user: {
          username: 'liuhuihui',
          age: 18,
          address: 'beijing'
        }
      },
      methods: {
      }
    })

  </script>

</body>

</html>